package com.zoagroup.funzy.entity.pk;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Embeddable;

/**
 * The primary key class for the ranking_group database table.
 * 
 */
@Embeddable
public class RankingGroupPK implements Serializable {
	private static final long serialVersionUID = 1L;

	@Column(name="id_ranking")
	private int idRanking;

	@Column(name="id_group")
	private int idGroup;

	public RankingGroupPK() {
	}

	public int getIdRanking() {
		return idRanking;
	}

	public void setIdRanking(int idRanking) {
		this.idRanking = idRanking;
	}

	public int getIdGroup() {
		return idGroup;
	}

	public void setIdGroup(int idGroup) {
		this.idGroup = idGroup;
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + idGroup;
		result = prime * result + idRanking;
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		RankingGroupPK other = (RankingGroupPK) obj;
		if (idGroup != other.idGroup)
			return false;
		if (idRanking != other.idRanking)
			return false;
		return true;
	}
}